Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: change git tree object format #305

Merged
merged 2 commits into from
Sep 23, 2021
Merged

Conversation

alexanderleegs
Copy link
Contributor

This PR fixes an issue with git trees being too large for sites with a large number of files. Previously, when we wanted to use git trees to delete/rename directories, we would send the information of every file in the repo as a git tree - this resulted in 502 errors as github was unable to parse such a large amount of files.

Recently, github has updated their API to allow for specifying that files are deleted via leaving the sha of the target files as null (see link). This method is much more space efficient, as the number of files deleted is significantly less than the total number of files in a repo.

We hypothesise that this PR will resolve our issues with unrecognised 502 errors.

Copy link
Contributor

@gweiying gweiying left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@alexanderleegs alexanderleegs merged commit 89b5810 into develop Sep 23, 2021
@alexanderleegs alexanderleegs deleted the fix/git-tree-format branch September 23, 2021 07:16
lamkeewei added a commit that referenced this pull request Nov 8, 2021
* develop: (25 commits)
  fix: package.json & package-lock.json to reduce vulnerabilities (#285)
  fix: package.json & package-lock.json to reduce vulnerabilities (#311)
  Refactor/collection refactor (#281)
  build(deps-dev): bump jest from 26.6.3 to 27.0.6 (#222)
  build(deps): bump tmpl from 1.0.4 to 1.0.5 (#304)
  build(deps): bump axios from 0.21.1 to 0.21.4 (#295)
  Fix: change git tree object format (#305)
  Fix: handle 409 errors when editing files (#303)
  hotfix: properly handle subcollection file update
  Fix: prevent truncating of page body (#299)
  Feat: add ability to edit description in settings (#280)
  ci: remove .ebextensions from zip
  ci: update backend staging eb env
  ci: update production eb env name (#298)
  ci: include .platform dir in deployment
  chore: specify node version
  chore: use EB platform hooks instead of ebextensions
  chore: add health check endpoint
  chore: use new cicd user creds
  fix: update ebextension to fix EB deploy
  ...
lamkeewei added a commit that referenced this pull request Nov 8, 2021
…token-middleware

* feat/identity/database-models: (25 commits)
  fix: package.json & package-lock.json to reduce vulnerabilities (#285)
  fix: package.json & package-lock.json to reduce vulnerabilities (#311)
  Refactor/collection refactor (#281)
  build(deps-dev): bump jest from 26.6.3 to 27.0.6 (#222)
  build(deps): bump tmpl from 1.0.4 to 1.0.5 (#304)
  build(deps): bump axios from 0.21.1 to 0.21.4 (#295)
  Fix: change git tree object format (#305)
  Fix: handle 409 errors when editing files (#303)
  hotfix: properly handle subcollection file update
  Fix: prevent truncating of page body (#299)
  Feat: add ability to edit description in settings (#280)
  ci: remove .ebextensions from zip
  ci: update backend staging eb env
  ci: update production eb env name (#298)
  ci: include .platform dir in deployment
  chore: specify node version
  chore: use EB platform hooks instead of ebextensions
  chore: add health check endpoint
  chore: use new cicd user creds
  fix: update ebextension to fix EB deploy
  ...
lamkeewei added a commit that referenced this pull request Nov 8, 2021
…/email-login

* feat/identity/site-token-middleware: (25 commits)
  fix: package.json & package-lock.json to reduce vulnerabilities (#285)
  fix: package.json & package-lock.json to reduce vulnerabilities (#311)
  Refactor/collection refactor (#281)
  build(deps-dev): bump jest from 26.6.3 to 27.0.6 (#222)
  build(deps): bump tmpl from 1.0.4 to 1.0.5 (#304)
  build(deps): bump axios from 0.21.1 to 0.21.4 (#295)
  Fix: change git tree object format (#305)
  Fix: handle 409 errors when editing files (#303)
  hotfix: properly handle subcollection file update
  Fix: prevent truncating of page body (#299)
  Feat: add ability to edit description in settings (#280)
  ci: remove .ebextensions from zip
  ci: update backend staging eb env
  ci: update production eb env name (#298)
  ci: include .platform dir in deployment
  chore: specify node version
  chore: use EB platform hooks instead of ebextensions
  chore: add health check endpoint
  chore: use new cicd user creds
  fix: update ebextension to fix EB deploy
  ...
harishv7 pushed a commit that referenced this pull request Feb 17, 2023
* Fix: change git tree object format

* Nit: add comments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants